package com.example.itcacp.service;

import com.example.itcacp.entity.Project;
import com.github.pagehelper.PageInfo;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;

public interface ProjectService {
    void createProject(Project project);

    List<Project> getAllProjects();

    PageInfo<Project> selectProjectsPage(Integer pageNum, Integer pageSize);

    Project getProjectById(Long projectId);

    Project updateProject(Project project);

    void deleteProject(Long projectId);

    String createGitRepo(Long userId, String projectPath) throws IOException, InterruptedException;

    void uploadFileToGit(Long projectId, MultipartFile file) throws IOException, InterruptedException;

    PageInfo<Project> selectProjectsPageByUser(Integer pageNum, Integer pageSize, Long userId);

    List<Project> selectProjectAllByUserId(Long userId);
}
